package com.ruoyi.system.domain.module.wx;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.io.Serializable;
import java.util.Date;
import java.math.BigDecimal;

/**
 * 用户分享后得现金奖励的记录对象 user_reg_cash_record
 *
 * @author ruoyi
 * @date 2022-06-10
 */
@Data
@NoArgsConstructor
@Accessors(chain = true)
@TableName("user_reg_cash_record")
public class UserRegCashRecord implements Serializable {

    private static final long serialVersionUID = 1L;


	/**
	 * $column.columnComment
	 */
	@TableId(value = "id",type = IdType.AUTO)
	private Long id;

	/**
	 *  记录类型 0 - 邀请个人用户  1 - 邀请商家
	 */
	private Integer recordType;
	/**
	 * 得现金红包的用户id
	 */
	private Integer userId;

	private Integer cashActiveId;

	/**
	 *  0 - 邀请者奖励  1 - 被邀请者奖励
	 */
	private Integer fromType;

	/**
	 * 分享后的用户的id
	 */
	private Integer regUserId;

	/**
	 *  入驻的商家id
	 */
	private Integer regMerId;
	/**
	 * 中奖金额
	 */
	@Excel(name = "中奖金额")
	private BigDecimal cashMoney;

	/**
	 * 添加时间
	 */
	@TableField(fill = FieldFill.INSERT)
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date createTime;

	/**
	 * 支付流水号
	 */
	private String tradeNo;

	/**
	 * 微信openid
	 */
	private String openId;


	/**
	 *  支付状态
	 */
	private Integer payState;


	/**
	 *  错误code
	 */
	private String errCodeDes;

	/**
	 *  结果code
	 */
	private String resultCode;
	/**
	 *  请求数据
	 */
	private String payStr;
	/**
	 *  响应数据
	 */
	private String rebackStr;



	@Excel(name = "添加时间")
	@TableField(exist = false)
	private String createTimeStr;

	@Excel(name = "支付状态")
	@TableField(exist = false)
	private String payStateStr;

	@Excel(name = "用户昵称")
    @TableField(exist = false)
    private String nickName;

	@TableField(exist = false)
	private String regFaceUrl;


	@Excel(name = "邀请的用户昵称")
	@TableField(exist = false)
	private String regNickName;

	@Excel(name = "邀请的商家名称")
	@TableField(exist = false)
	private String regMerName;

	@TableField(exist = false)
	private String faceUrl;

	@TableField(exist = false)
	private String beginDate;

	@TableField(exist = false)
	private String endDate;


}
